// ----------------------------------------------------------------------------
/**
 * @file    LoginWindow.h
 *
 * @brief   Header file for LoginWindow.cpp
 *
 * The loginwindow is the way that the user logs in to the server.
 *
 * @author  Siddharth Sathyam <ssathy2@gmail.com>
 * @author  Alan Ruvalcaba <aruval3@gmail.com>
 * @author  Patrick LaMontagna <plamontagna@gmail.com
 *
 * @version 1.0
 *
 * @date    November 24th, 2011
 *
 */
// ----------------------------------------------------------------------------

#ifndef LOGINWINDOW_H
#define LOGINWINDOW_H

#include <QMainWindow>
#include "client.h"
#include "contactlist.h"
#include "QWidget"

namespace Ui {
    class LoginWindow;
}

/**
 * @class   LoginWindow
 *
 * @brief   The LoginWindow helper methods
 *
 */

class LoginWindow : public QMainWindow
{
    Q_OBJECT

public:

    /// Explicit Constructor for LoginWindow
    explicit LoginWindow(QWidget *parent = 0);

    /// Deconstructor for LoginWindow
    ~LoginWindow();

private slots:

    /**
    * @brief Slot that determines if the user clicks the quit button
    */

    void on_QuitButton_clicked();

    /**
    * @brief Slot that determines if the user clicks the about button
    */

    void on_AboutButton_clicked();

    /**
    * @brief Slot that determines if the user clicks the login button
    */

    void on_LoginButton_clicked();

    /**
    * @brief Slot that determines if the user has entered text in the username field
    * @param arg1 The desired username entered by the user
    */

    void on_nameBox_textEdited(const QString &arg1);

private:
    Ui::LoginWindow *ui;

    /// login Socket variable
    Client *loginSocket;

    /// username name variable
    QString name;

bool eventFilter(QObject *ob, QEvent *e);
};

#endif // LOGINWINDOW_H



